﻿@using CodeCamp.Models.Schedule
@using CodeCamp.Models.Shared
@using CodeCamp.Infrastructure.Extensions
@model ScheduleBuildingEditViewModel
@{
    ViewBag.Title = "";
    string headline;
    if ((@Model != null) && (@Model.EventDisplayName != null))
    {
        ViewBag.Title = @Html.Encode(@Model.EventDisplayName + " | Add Building");
        headline = @Model.EventDisplayName + " Add Building";
    }
    else
    {
        ViewBag.Title = "Code Camp | Add Building";
        headline = "Code Camp - Add Building";
    }
}

<h2>@headline</h2>

@if (Model.Building != null)
{
    @Html.Partial("Partial/EditBuildingPartial", Model.Building)
}

<div>
    @Html.ActionLink("Back to List", "Buildings")
</div>
